package org.jeecg.modules.xl.aftersale.mapper;

import java.util.List;

import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import   org.jeecg.modules.xl.aftersale.entity.XlCustomerAftersale;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;

/**
 * @Description: 售后单
 * @Author: jeecg-boot
 * @Date:   2024-11-03
 * @Version: V1.0
 */
public interface XlCustomerAftersaleMapper extends BaseMapper<XlCustomerAftersale> {
    @Select("" +
            "SELECT  " +
            "    MAX(SUBSTRING(SUBSTRING_INDEX(workorder, #{pre}, -1), 1)) AS maxNumber " +
            "FROM  " +
            "    xl_customer_aftersale " +
            "WHERE  " +
            "    workorder LIKE concat('%',#{pre},'%') " +
            "")
    String queryMaxCodeNumber(String pre);

}
